from sense_hat import sense_hat

sense = sense_hat()
#变换led矩阵方向
sense.set_rotation(180)
X = [255,0,0]
O = [255,255,255]#white
question_mark = [
    X,X,X,X,X,X,X,X,
    X,X,X,X,X,X,X,X,
    X,X,X,X,X,X,X,X,
    X,X,X,X,X,X,X,X,
    X,X,X,X,X,X,X,X,
    X,X,X,X,X,X,X,X,
    X,X,X,X,X,X,X,X,
    X,X,X,X,X,X,X,X
]
sense.set_pixels(question_mark)
while True:
    sense.show_message("Hello world!")
